package es.udc.emarketapp.emarket.model.shipping.dao;

import es.udc.emarketapp.emarket.model.country.vo.CountryVO;
import es.udc.emarketapp.emarket.model.shipping.vo.ShippingVO;
import es.udc.fbellas.j2ee.util.exceptions.InstanceNotFoundException;
import es.udc.fbellas.j2ee.util.exceptions.InternalErrorException;
import es.udc.fbellas.j2ee.util.exceptions.ModelException;
import java.sql.Connection;
import java.util.List;



public interface SQLShippingDAO {
	
	public ShippingVO create(Connection connection, ShippingVO shippingVO)
		throws InternalErrorException;
	
	public boolean exists(Connection connection, ShippingVO shippingVO)
		throws InternalErrorException;

        public List<ShippingVO> findRates(Connection connection,
                String idSeller, String country, int startIndex,
                int count) throws InternalErrorException;

        public Double findCost(Connection connection,
                String idSeller, String idCountry, Double weight)
                throws ModelException, InternalErrorException;

	public List<String> findCountriesBySeller(Connection connection,
		String idSeller, int startIndex, int count)
		throws InternalErrorException;
	
	public void update(Connection connection, ShippingVO shippingVO)
		throws InstanceNotFoundException, InternalErrorException;

        public void remove(Connection connection, String idVendedor, String idPais)
            throws InstanceNotFoundException, InternalErrorException;
	 
	public void remove(Connection connection, ShippingVO shippingVO)
		throws InstanceNotFoundException, InternalErrorException;

}